﻿using System;
using System.Linq;
using System.Collections.Generic;
using System.Text;

namespace RobotCtrl
{
    public class RobotConsole
    {
        private DigitalIn switches;
        private DigitalOut lamps;

        public DigitalIn Switches   { get { return switches; } }
        public DigitalOut Lamps     { get { return lamps; } }

        public RobotConsole(RunMode mode)
		{
            if (!Config.IsWinCE)
            {
                mode = RunMode.VIRTUAL;
            }

			if (mode == RunMode.VIRTUAL)
			{
				switches = new DigitalIn();
				lamps = new DigitalOut();
			}
			else
			{
				switches = new DigitalIn_HW(Config.IOConsoleSWITCH);
				lamps = new DigitalOut_HW(Config.IOConsoleLED);
			}
		}

    }
}
